/* Fanxxx Template v2 — editorial slate + amber accent */
:root {
    --fx-ink: #1a191f;
    --fx-ink-2: #2d2a32;
    --fx-muted: #6b6874;
    --fx-line: #e8e6e1;
    --fx-bg: #f4f3ef;
    --fx-card: #ffffff;
    --fx-accent: #f9ab00;
    --fx-accent-2: #ffc83d;
    --fx-accent-soft: rgba(249,171,0,.12);
    --fx-blue: #3d6fd8;
    --fx-r: 10px;
    --fx-r-lg: 16px;
    --fx-shadow: 0 1px 2px rgba(26,25,31,.06), 0 8px 24px -8px rgba(26,25,31,.12);
    --fx-shadow-lg: 0 12px 40px -16px rgba(26,25,31,.22);
    --fx-max: 1180px;
    --fx-side: 300px;
    --fx-ease: cubic-bezier(.4,0,.2,1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: "Source Sans Pro", -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
    font-size: 16px;
    line-height: 1.75;
    color: var(--fx-ink-2);
    background: var(--fx-bg);
    -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--fx-blue); text-decoration: none; transition: color .2s var(--fx-ease); }
a:hover { color: var(--fx-accent); }
.hidden { display: none !important; }

.fx-wrap { max-width: var(--fx-max); margin: 0 auto; padding: 0 20px; }

/* progress */
.fx-progress {
    position: fixed; top: 0; left: 0; height: 3px; width: 0;
    background: linear-gradient(90deg, var(--fx-accent-2), var(--fx-accent));
    z-index: 1100;
}

/* header */
.fx-header {
    position: sticky; top: 0; z-index: 1000;
    background: rgba(26,25,31,.94);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255,255,255,.06);
}
.fx-header__inner {
    display: flex; align-items: center; justify-content: space-between;
    height: 64px; gap: 1rem;
}
.fx-logo {
    display: inline-flex; align-items: center; gap: .6rem;
    color: #fff; font-weight: 800; font-size: 1.05rem;
}
.fx-logo__mark {
    width: 36px; height: 36px; border-radius: 10px;
    background: linear-gradient(135deg, var(--fx-accent-2), var(--fx-accent));
    color: var(--fx-ink); font-weight: 900;
    display: flex; align-items: center; justify-content: center;
}
.fx-nav { display: flex; gap: .35rem; }
.fx-nav a {
    color: rgba(255,255,255,.72); font-size: .88rem; font-weight: 600;
    padding: .4rem .75rem; border-radius: 999px; transition: .2s;
}
.fx-nav a:hover, .fx-nav a.is-active {
    color: var(--fx-ink); background: var(--fx-accent);
}
.fx-menu-btn {
    display: none; background: none; border: none;
    color: #fff; font-size: 1.4rem; cursor: pointer;
}
.fx-mobile-nav {
    background: var(--fx-ink); border-top: 1px solid rgba(255,255,255,.08);
    padding: .5rem 0 1rem;
}
.fx-mobile-nav .fx-nav { flex-direction: column; gap: 0; }
.fx-mobile-nav .fx-nav a { border-radius: 8px; padding: .65rem 1rem; }

/* hero (index) */
.fx-hero {
    margin: 1.5rem 0;
    padding: 2.5rem 2rem;
    border-radius: var(--fx-r-lg);
    background:
        radial-gradient(800px 300px at 100% 0%, rgba(249,171,0,.18), transparent 60%),
        linear-gradient(135deg, var(--fx-ink) 0%, #2b2835 100%);
    color: #fff;
    box-shadow: var(--fx-shadow-lg);
}
.fx-hero__tag {
    display: inline-block; font-size: .75rem; font-weight: 700;
    letter-spacing: .08em; text-transform: uppercase;
    color: var(--fx-accent-2); margin-bottom: .75rem;
}
.fx-hero__title {
    margin: 0 0 .75rem; font-size: clamp(1.6rem, 4vw, 2.4rem);
    line-height: 1.25; font-weight: 800;
}
.fx-hero__desc { margin: 0; color: rgba(255,255,255,.78); max-width: 640px; }

/* list banner */
.fx-list-head {
    margin: 1.25rem 0; padding: 1.25rem 1.5rem;
    background: var(--fx-card); border: 1px solid var(--fx-line);
    border-radius: var(--fx-r-lg); box-shadow: var(--fx-shadow);
}
.fx-list-head h1 { margin: 0 0 .35rem; font-size: 1.5rem; color: var(--fx-ink); }
.fx-list-head p { margin: 0; color: var(--fx-muted); font-size: .92rem; }

/* breadcrumb */
.fx-crumb {
    display: flex; flex-wrap: wrap; align-items: center; gap: .4rem;
    font-size: .82rem; color: var(--fx-muted);
    padding: 1.1rem 0 .25rem;
}
.fx-crumb a { color: var(--fx-muted); }
.fx-crumb a:hover { color: var(--fx-accent); }
.fx-crumb strong { color: var(--fx-ink); font-weight: 600; }

/* layout */
.fx-layout {
    display: grid;
    grid-template-columns: 1fr var(--fx-side);
    gap: 1.75rem;
    padding-bottom: 2.5rem;
}
@media (max-width: 992px) {
    .fx-layout { grid-template-columns: 1fr; }
    .fx-nav { display: none; }
    .fx-menu-btn { display: block; }
}

/* article card */
.fx-article {
    background: var(--fx-card);
    border: 1px solid var(--fx-line);
    border-radius: var(--fx-r-lg);
    box-shadow: var(--fx-shadow);
    overflow: hidden;
}
.fx-article__head { padding: 1.75rem 1.75rem 1.25rem; border-bottom: 1px solid var(--fx-line); }
.fx-pill {
    display: inline-block; font-size: .76rem; font-weight: 700;
    padding: .25rem .65rem; border-radius: 999px;
    background: var(--fx-accent-soft); color: #9a6b00;
    margin-bottom: .85rem;
}
.fx-article__title {
    margin: 0 0 1rem; font-size: clamp(1.45rem, 3vw, 2rem);
    line-height: 1.3; font-weight: 800; color: var(--fx-ink);
}
.fx-meta {
    display: flex; flex-wrap: wrap; align-items: flex-start;
    justify-content: space-between; gap: 1rem 1.25rem;
}
.fx-meta__info {
    display: flex; flex-wrap: wrap; align-items: center; gap: 1rem .85rem;
    font-size: .84rem; color: var(--fx-muted);
}
.fx-meta__author { display: inline-flex; align-items: center; gap: .5rem; }
.fx-meta__author img {
    width: 34px; height: 34px; border-radius: 50%; object-fit: cover;
    border: 2px solid var(--fx-line);
}
.fx-meta__actions {
    display: flex; flex-wrap: wrap; align-items: center; gap: .65rem 1rem;
}
.fx-subscribe-btn {
    display: inline-flex; align-items: center; gap: .3rem;
    padding: .45rem 1.05rem; border-radius: 999px;
    background: linear-gradient(135deg, var(--fx-accent-2), var(--fx-accent));
    color: var(--fx-ink); font-size: .82rem; font-weight: 700;
    box-shadow: 0 2px 8px rgba(249,171,0,.35);
    transition: transform .2s var(--fx-ease), box-shadow .2s var(--fx-ease);
}
.fx-subscribe-btn:hover {
    color: var(--fx-ink); transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(249,171,0,.45);
}
.fx-subscribe-btn.is-subscribed {
    background: var(--fx-ink-2); color: #fff;
    box-shadow: none;
}
.fx-share-toast {
    position: fixed; left: 50%; bottom: 1.5rem; z-index: 1200;
    transform: translateX(-50%) translateY(120%);
    padding: .65rem 1.1rem; border-radius: 999px;
    background: rgba(26,25,31,.92); color: #fff;
    font-size: .84rem; box-shadow: var(--fx-shadow-lg);
    transition: transform .28s var(--fx-ease); pointer-events: none;
}
.fx-share-toast.is-visible { transform: translateX(-50%) translateY(0); }
.fx-wechat-share {
    position: fixed; inset: 0; z-index: 1300;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; visibility: hidden; transition: .25s;
}
.fx-wechat-share.is-visible { opacity: 1; visibility: visible; }
.fx-wechat-share__backdrop {
    position: absolute; inset: 0; background: rgba(0,0,0,.45);
}
.fx-wechat-share__box {
    position: relative; z-index: 1; width: min(92vw, 320px);
    padding: 1.35rem 1.25rem 1.1rem; text-align: center;
    background: var(--fx-card); border-radius: var(--fx-r-lg);
    box-shadow: var(--fx-shadow-lg);
}
.fx-wechat-share__box h4 { margin: 0 0 .85rem; font-size: 1rem; color: var(--fx-ink); }
.fx-wechat-share__qr {
    width: 220px; height: 220px; margin: 0 auto .75rem;
    border-radius: var(--fx-r); border: 1px solid var(--fx-line);
}
.fx-wechat-share__box p { margin: 0 0 1rem; font-size: .82rem; color: var(--fx-muted); }
.fx-wechat-share__close {
    border: none; border-radius: 999px; padding: .45rem 1.2rem;
    background: var(--fx-accent); color: var(--fx-ink);
    font-weight: 700; font-size: .82rem; cursor: pointer;
}
.fx-share { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.fx-share__label {
    font-size: .78rem; font-weight: 600; color: var(--fx-muted);
    letter-spacing: .02em;
}
.fx-share__icons {
    display: flex; flex-wrap: wrap; align-items: center; gap: .35rem;
}
.fx-share__btn {
    display: inline-flex; align-items: center; justify-content: center;
    width: 32px; height: 32px; border-radius: 50%;
    color: #fff; transition: transform .2s var(--fx-ease), box-shadow .2s var(--fx-ease);
}
.fx-share__btn svg { width: 18px; height: 18px; fill: currentColor; }
.fx-share__btn:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,.18); }
.fx-share__btn--wechat { background: #07c160; }
.fx-share__btn--weibo { background: #e6162d; }
.fx-share__btn--qq { background: #12b7f5; }
.fx-share__btn--qzone { background: #fac907; color: #5c4b00; }
.fx-share__btn--douyin { background: #111; }
.fx-share__btn--xiaohongshu { background: #ff2442; }
.fx-share__btn--bilibili { background: #fb7299; }
.fx-share__btn--zhihu { background: #0066ff; }
.fx-share__btn--kuaishou { background: #ff4906; }
.fx-share__btn--tieba { background: #2e5fb3; }
.fx-share__btn--douban { background: #2e963e; }
.fx-share__btn--toutiao { background: #f04142; }
@media (max-width: 576px) {
    .fx-meta__actions { width: 100%; }
    .fx-share__icons { gap: .3rem; }
}

.fx-article__body { padding: 1.5rem 1.75rem 1.75rem; }

/* excerpt */
.fx-lead {
    padding: 1.1rem 1.25rem;
    background: linear-gradient(90deg, var(--fx-accent-soft), transparent);
    border-left: 4px solid var(--fx-accent);
    border-radius: 0 var(--fx-r) var(--fx-r) 0;
    margin-bottom: 1.5rem;
}
.fx-lead h3 { margin: 0 0 .45rem; font-size: 1rem; color: var(--fx-ink); }
.fx-lead p { margin: 0; color: var(--fx-muted); }

/* image grid */
.fx-gallery {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: .85rem;
    margin: 1.25rem 0 1.5rem;
}
.fx-gallery__item { border-radius: var(--fx-r); overflow: hidden; aspect-ratio: 16/10; }
.fx-gallery__item img { width: 100%; height: 100%; object-fit: cover; }
.fx-gallery__item:first-child { grid-column: 1 / -1; aspect-ratio: 21/9; }
@media (max-width: 576px) { .fx-gallery { grid-template-columns: 1fr; } .fx-gallery__item:first-child { grid-column: auto; } }

/* content */
.fx-content h2 {
    margin: 1.75rem 0 .85rem; font-size: 1.35rem;
    color: var(--fx-ink); font-weight: 700;
    padding-bottom: .45rem; border-bottom: 2px solid var(--fx-accent-soft);
}
.fx-content p { margin: 0 0 1rem; }
.fx-callout {
    margin: 1.5rem 0; padding: 1.1rem 1.25rem;
    background: var(--fx-bg); border: 1px solid var(--fx-line);
    border-radius: var(--fx-r);
}
.fx-callout h3 { margin: 0 0 .5rem; font-size: 1rem; color: var(--fx-ink); }

/* tags */
.fx-tags { margin-top: 1.75rem; padding-top: 1.25rem; border-top: 1px solid var(--fx-line); }
.fx-tags__label { font-size: .82rem; font-weight: 700; color: var(--fx-muted); margin-bottom: .65rem; }
.fx-tags__list { display: flex; flex-wrap: wrap; gap: .45rem; }
.fx-tag {
    display: inline-block; font-size: .8rem; font-weight: 600;
    padding: .3rem .7rem; border-radius: 999px;
    background: var(--fx-bg); border: 1px solid var(--fx-line);
    color: var(--fx-ink-2);
}
.fx-tag:hover { border-color: var(--fx-accent); background: var(--fx-accent-soft); color: var(--fx-ink); }

/* sidebar */
.fx-aside { display: flex; flex-direction: column; gap: 1rem; }
@media (min-width: 993px) { .fx-aside { position: sticky; top: 80px; align-self: start; } }
.fx-widget {
    background: var(--fx-card); border: 1px solid var(--fx-line);
    border-radius: var(--fx-r-lg); padding: 1.1rem 1.15rem;
    box-shadow: var(--fx-shadow);
}
.fx-widget__title {
    margin: 0 0 .85rem; font-size: .92rem; font-weight: 700;
    color: var(--fx-ink); display: flex; align-items: center; gap: .4rem;
}
.fx-search { position: relative; }
.fx-search input {
    width: 100%; padding: .6rem .75rem .6rem 2.2rem;
    border: 1px solid var(--fx-line); border-radius: var(--fx-r);
    font-size: .88rem; background: var(--fx-bg);
}
.fx-search input:focus { outline: none; border-color: var(--fx-accent); box-shadow: 0 0 0 3px var(--fx-accent-soft); }
.fx-search__icon {
    position: absolute; left: .7rem; top: 50%; transform: translateY(-50%);
    color: var(--fx-muted); font-size: .9rem;
}
.fx-toc { list-style: none; margin: 0; padding: 0; }
.fx-toc li { border-bottom: 1px dashed var(--fx-line); }
.fx-toc li:last-child { border-bottom: none; }
.fx-toc a {
    display: block; padding: .55rem 0; font-size: .86rem;
    color: var(--fx-ink-2);
}
.fx-toc a:hover { color: var(--fx-accent); padding-left: .25rem; }
/* v1 toc-list: ghost link + content link per row */
.fx-toc.toc-list li {
    margin-bottom: .15rem;
    border-bottom: 1px dashed var(--fx-line);
}
.fx-toc.toc-list li:last-child { border-bottom: none; }
.fx-toc.toc-list a {
    font-size: .9rem;
    color: var(--fx-ink-2);
    border-bottom: none;
}

.fx-hot { display: flex; gap: .65rem; padding: .55rem 0; border-bottom: 1px dashed var(--fx-line); }
.fx-hot:last-child { border-bottom: none; }
.fx-hot img { width: 56px; height: 56px; border-radius: 8px; object-fit: cover; flex-shrink: 0; }
.fx-hot__title { font-size: .84rem; line-height: 1.35; color: var(--fx-ink); font-weight: 600; }
.fx-hot__date { font-size: .72rem; color: var(--fx-muted); margin-top: .2rem; }

/* related / list grid — v1 article-item structure + v2 polish */
.fx-section,
.related-articles { margin: 2rem 0 0; }
.fx-section__title,
.related-title {
    margin: 0 0 1.25rem; font-size: 1.35rem; font-weight: 800; color: var(--fx-ink);
}
.fx-grid,
.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem;
}
@media (max-width: 768px) { .fx-grid, .articles-grid { grid-template-columns: 1fr; } }
.fx-card,
.article-item {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: var(--fx-card); border: 1px solid var(--fx-line);
    border-radius: var(--fx-r-lg); overflow: hidden;
    box-shadow: var(--fx-shadow); transition: .25s var(--fx-ease);
}
.fx-card:hover,
.article-item:hover { transform: translateY(-4px); box-shadow: var(--fx-shadow-lg); }
.fx-card__media,
.fx-card__img {
    display: block;
    overflow: hidden;
    flex-shrink: 0;
}
.fx-card__media img,
.fx-card__img img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
    transition: transform .35s var(--fx-ease);
}
.fx-card:hover .fx-card__media img,
.fx-card:hover .fx-card__img img { transform: scale(1.04); }
.fx-card__body,
.article-item-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 1.15rem 1.25rem 1.25rem;
}
.fx-card__cat,
.article-item-category {
    display: block;
    font-size: .8rem; font-weight: 700; color: var(--fx-accent);
    text-transform: uppercase; letter-spacing: .04em;
    margin-bottom: .5rem;
}
.fx-card__title,
.article-item-title {
    margin: 0 0 .55rem; font-size: 1.1rem; line-height: 1.4;
    color: var(--fx-ink); font-weight: 700;
}
.fx-card__title a { color: inherit; }
.fx-card__title a:hover { color: var(--fx-accent); }
.fx-card__desc {
    margin: 0 0 .75rem;
    font-size: .86rem; line-height: 1.6; color: var(--fx-muted);
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.fx-card__meta,
.article-item-meta {
    margin-top: auto;
    font-size: .85rem; color: var(--fx-muted);
}

/* footer */
.fx-footer {
    background: var(--fx-ink); color: rgba(255,255,255,.75);
    padding: 2.5rem 0 1.25rem; margin-top: 2rem;
}
.fx-footer__grid {
    display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 1.5rem;
}
@media (max-width: 768px) { .fx-footer__grid { grid-template-columns: 1fr 1fr; } }
.fx-footer h3 { color: #fff; font-size: .95rem; margin: 0 0 .85rem; }
.fx-footer p { margin: 0; font-size: .86rem; line-height: 1.65; color: rgba(255,255,255,.65); }
.fx-footer ul { list-style: none; margin: 0; padding: 0; }
.fx-footer li { margin-bottom: .45rem; }
.fx-footer a { color: rgba(255,255,255,.65); font-size: .86rem; }
.fx-footer a:hover { color: var(--fx-accent-2); }
.fx-copy {
    text-align: center; margin-top: 1.75rem; padding-top: 1.25rem;
    border-top: 1px solid rgba(255,255,255,.1);
    font-size: .8rem; color: rgba(255,255,255,.45);
}

/* utilities */
.fx-back-top {
    position: fixed; right: 1.25rem; bottom: 1.25rem;
    width: 44px; height: 44px; border-radius: 50%; border: none;
    background: var(--fx-accent); color: var(--fx-ink); font-weight: 800;
    box-shadow: var(--fx-shadow-lg); cursor: pointer;
    opacity: 0; visibility: hidden; transition: .25s; z-index: 900;
}
.fx-back-top.is-visible { opacity: 1; visibility: visible; }

.seo-content {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}